#include <iostream>

class RentHouse
{
public:
    virtual void rentHouse() = 0;
    virtual ~RentHouse() = default;
};

class LandLord : public RentHouse
{
public:
    void rentHouse() override
    {
        std::cout << "rent house" << std::endl;
    }
};

class Intermediary : public RentHouse
{
public:
    void rentHouse() override
    {
        std::cout << "发布招租启事\n";
        std::cout << "带人看房\n";
        _landlord.rentHouse();
        std::cout << "负责租后维修\n";
    }

private:
    LandLord _landlord;
};

int main()
{
    Intermediary intermediary;
    intermediary.rentHouse();

    return 0;
}